/*!
 * mars
 * Copyright(c) 2016 huangbinglong
 * MIT Licensed
 */

'use strict';

angular.module("dayu.demo.http",["dayu.ui.http"])
    .controller("indexController",function(DayuHttp) {
        DayuHttp("queryByDefno_action").baseUrl("/example/dayuHttp/data.json").params({
            "defno": "rolename"
        }).get({},function(res) {  // 可以get或者post
            alert("数据："+JSON.stringify(res));
        },function(error) {
            console.log(error);
        }).then(function(res) {
            console.log(res);
        });
    });
